import request from '@/utils/request'

// 创建RFID信息
export function createRfid(data) {
  return request({
    url: '/hs/rfid/create',
    method: 'post',
    data: data
  })
}

// 更新RFID信息
export function updateRfid(data) {
  return request({
    url: '/hs/rfid/update',
    method: 'put',
    data: data
  })
}

// 删除RFID信息
export function deleteRfid(id) {
  return request({
    url: '/hs/rfid/delete?id=' + id,
    method: 'delete'
  })
}

// 获得RFID信息
export function getRfid(id) {
  return request({
    url: '/hs/rfid/get?id=' + id,
    method: 'get'
  })
}

// 获得RFID信息分页
export function getRfidPage(params) {
  return request({
    url: '/hs/rfid/page',
    method: 'get',
    params
  })
}
// 导出RFID信息 Excel
export function exportRfidExcel(params) {
  return request({
    url: '/hs/rfid/export-excel',
    method: 'get',
    params,
    responseType: 'blob'
  })
}

// 更换标签
export function change(data) {
  return request({
    url: '/hs/rfid/change',
    method: 'post',
    data: data,
  })
}
